﻿<%@ Page Title="" Language="C#" MasterPageFile="~/Admin.Master" AutoEventWireup="true" CodeFile="ViewPatients.aspx.cs" Inherits="FYP14.ViewPatients" %>
<asp:Content ID="Content1" ContentPlaceHolderID="head" runat="server">
</asp:Content>
<asp:Content ID="Content2" ContentPlaceHolderID="adminpnl" runat="server">
    <div class="right_content">
        <h2>View All Patients</h2>
        <asp:GridView ID="gvPurchase" runat="server" AutoGenerateColumns="False" CssClass="rounded-corner"
                    RowStyle-CssClass="gridRow" EditRowStyle-CssClass="gridEditRow"
                    FooterStyle-CssClass="gridFooterRow" OnRowDataBound="gvPurchase_RowDataBound" DataKeyNames="patient_id" 
                    AllowPaging="True" AllowSorting="True" onpageindexchanging="gvPurchase_PageIndexChanging" PageSize="10">
                    <AlternatingRowStyle CssClass="gridAltRow"></AlternatingRowStyle>
                    <columns>
                        <asp:BoundField DataField="patient_id" HeaderText="ID"/>
                        <asp:BoundField DataField="name" HeaderText="Name"/>
                        <asp:BoundField DataField="dob" HeaderText="Date Of Birth" DataFormatString="{0:yyyy-MM-dd}" HtmlEncode="false"/>
                        
                        <asp:BoundField DataField="record_no" HeaderText="Record No"/>
                        <asp:BoundField DataField="nic" HeaderText="NIC"/>
                        <asp:BoundField DataField="gender" HeaderText="Gender"/>
                        <asp:BoundField DataField="age" HeaderText="Age"/>
                        <asp:BoundField DataField="contact_number" HeaderText="Contact Number"/>
                        <asp:BoundField DataField="address" HeaderText="Address"/>
                        <asp:TemplateField>
                            <ItemTemplate>
                                <asp:ImageButton ID="lnkEdit" runat="server" onclick="lnkRemove_Click" CommandArgument='<%# Eval("patient_id") %>' ImageUrl="images/user_edit.png"></asp:ImageButton>
                            </ItemTemplate>
                         </asp:TemplateField>
                     </columns>
                    <EditRowStyle CssClass="gridEditRow"></EditRowStyle>
                    <FooterStyle CssClass="gridFooterRow"></FooterStyle>
                    <RowStyle CssClass="gridRow"></RowStyle>
                    <PagerSettings FirstPageText="First" LastPageText="Last" NextPageText="Next" PreviousPageText="Previous" />
                    <PagerStyle CssClass="grid_paging" />
                </asp:GridView>
        </div>
</asp:Content>
